package com.huahang.fashionpress.form;

import com.huahang.fashionpress.model.Category;
import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.Size;
import java.math.BigDecimal;

/**
 * 商品面向表单的对象
 * @Author: 阿俊哥
 * @Date: 2019/8/23 10:44
 * @Version 1.0
 */
@Data
public class FormProduct {
    /*productId*/
    private String productId;

    /*product_name*/
    @NotEmpty(message = "商品名字不能为空")
    private String productName;

    /*product_price*/
    @Min(value = 0,message = "商品单价不能为空")
    private BigDecimal productPrice;

    /*product_inventory*/
    @Min(value = 1,message = "库存不能小于1")
    private Integer productInventory;

    /*product_describe*/
    @NotEmpty
    private String productDescribe;

    /*product_status*/
    private Integer productStatus;

    /*category_id*/

    private Integer categoryId;

    private Integer productQuantity;
}
